package com.bjpowernode.gateway.web.model.query;

import jakarta.validation.constraints.*;
import lombok.Data;

import java.math.BigDecimal;

/**
 * 交易信息 数据模型
 */
@Data
public class TradeReceiveQuery {

    @NotBlank(message = "userNo不能为空")
    private String userNo;
    @NotBlank(message = "appKey不能为空")
    private String appKey;
    @NotBlank(message = "payProductCode不能为空")
    private String payProductCode;
    @NotBlank(message = "productId不能为空")
    private String productId;
    @NotBlank(message = "productName不能为空")
    private String productName;
    @NotNull(message = "productNum不能为空")
    @Min(value = 1, message = "商户数量需要大于等于1")
    private Integer productNum;
    @NotBlank(message = "payerId不能为空")
    private String payerId;
    @NotBlank(message = "payerConcat不能为空")
    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "联系方式格式错误")
    private String payerConcat;
    @NotNull(message = "orderMoney不能为空")
    @DecimalMin(value = "0", message = "订单金额不能小于0")
    private BigDecimal orderMoney;
    @NotBlank(message = "pageUrl不能为空")
    private String pageUrl;
    @NotBlank(message = "notifyUrl不能为空")
    private String notifyUrl;
    @NotBlank(message = "orderNo不能为空")
    private String orderNo;
    @NotBlank(message = "sign不能为空")
    private String sign;
}
